package com.zzyl.mapper;

import com.github.pagehelper.Page;
import com.zzyl.aop.AutoFill;
import com.zzyl.dto.NursingPlanPageQueryDto;
import com.zzyl.entity.NursingPlan;
import com.zzyl.vo.NursingPlanVo;
import org.apache.ibatis.annotations.Delete;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Select;

import java.util.List;

@Mapper
public interface NursingPlanMapper {

    @Select("select * from nursing_plan")
    List<NursingPlanVo> findAll();


    Page<NursingPlanVo> query(NursingPlanPageQueryDto dto);

    @AutoFill
    void add(NursingPlan nursingPlan);

    @Select("select * from nursing_plan where id=#{id}")
    NursingPlan getById(Integer id);

    @AutoFill
    void update(NursingPlan nursingPlan);

    @Delete("delete from nursing_plan where id=#{id}")
    void deleteid(Integer id);

    /*@Select("select * from nursing_plan")
    NursingPlanVo getById(Integer id);*/
}
